class User {
  fullName:string;

  constructor(public firstName:string, public lastName:string) {
    this.fullName = firstName + " " + lastName 
  }
}

interface Person {
  firstName:string;
  lastName: string;
}

function greeter (person:Person) {
  return 'Hello '+ person.firstName + ' '+ person.lastName
}

let person:Person = {
  firstName: 'jiang',
  lastName: 'xuemei'
}

let user = new User('jiang', 'xuemei')

let res = greeter(user)

console.log(res)